The present invention relates to a network interface apparatus and a method of controlling the transmission and reception of a frame and, more particularly, to an interface apparatus and a method of controlling the transmission and reception of a frame in a network which utilizes a CSMA/CD (Carriers Sense Multiple Access with Collision Detection) system.
Recently, LANs have increasingly been introduced into offices and homes, and the flow of the frames which are required to have a real-time nature on the LAN through an internet or an intranet such as moving pictures and sound has been rapidly increasing with the spread of internets/intranets. Under the CSMA/CD system, however, if the flow of the frames increases, a collision on a transmission medium is of frequent occurrence, which leads to long transmission delays, so that it is impossible to secure a real-time nature which frames are required to have, and as a result, it is impossible to ensure the QoS (Quality of Service) thereof. Therefore, the guarantee of the QoS as to the real-time nature is now demanded in the CSMA/CD system.
At present, attempts to control the QoS by reserving resources by using a protocol such as RSVP (Resource Reservation Protocol) and diff serve are continued as to an upper layer such as an IP (Internet Protocol) layer. In the present situation, however, the strict QoS control is not realized in a LAN as a lower layer, which uses the widespread CSMA/CD system.
FIG. 34 are explanatory views of the principle of the CSMA/CD system in a LAN. In the drawings, a horizontal line L indicates a shared transmission line such as a bus consisting of a coaxial cable. To short branches of the bus are connected stations such as terminals and a host. When a terminal A has data to be transmitted, it confirms whether signals (carriers) are flowing on the bus L or not, and if there are no signals, it transmits a frame FA. At this time, there is a possibility of another terminal B transmitting a frame FB approximately at the same time, more strictly, before the frame FA which the terminal A transmits does not reach the terminal B. In such a case, the frame FA which has been transmitted from the terminal A and the frame FB which has been transmitted from the terminal B collide with each other somewhere between A and B, so that the data of both frames are destroyed.
In the CSMA/CD system, it is necessary to monitor whether such a collision has occurred or not, and to retransmit a frame if there is a collision. For this purpose, the terminals A and B which have transmitted the frames do not stop monitoring whether a collision occurs or not during the transmission. Since the signal transmitted from the terminal A propagates on both ways along the bus L, it reaches the terminal B after a certain time. At this point of time, the terminal B, which has started transmission, detects a collision. The terminal B then sends a random signal which is called a jam signal for reporting the occurrence of the collision to other terminal for some consecutive time. Some time after the detection of the collision by the terminal B, the frame transmitted from the terminal B reaches the terminal A, which also detects a collision and sends a jam signal. After jam signals are sent for a certain time, both the terminals A and B keep silent. This silent time is called a back-off time. After the back-off time is elapsed, the terminals A and B confirm that the transmission line is idle, and then restarts the transmission operation.
If the back-off times of all the terminals are the same, since the terminals A and B restart the transmission operation approximately at the same time, so that a collision occurs again. To prevent this, the CSMA/CD system adopts a back-off algorithm to prevent the repetition of a collision and to give an equal chance of transmitting a frame to each terminal. Owing to this algorithm, there is a large difference in the back-off time between the terminals A and B, so that there is a high probability of one keeping silent even if the other starts retransmission, and the chance for a second collision is scarce.
In the CSMA/CD system, the minimum frame length is prescribed in order to detect a collision. It is here assumed that the time necessary for the frame which the terminal A′ on the left-most end of the bus has transmitted to reach the destination terminal B′ on the right-most end of the bus is Tm. If the terminal B′ starts the transmission of a frame just Tm after the terminal A′ has started transmission, the frame of the terminal B′ immediately collides. A slight time Tc elapses until the terminal B′ detects the collision. Then the terminal B′ sends a jam signal, which reaches the terminal A′ after Tm. Accordingly, the terminal A′ does not perceive the collision and may mistakenly judge that the frame has safely reached the destination, if the terminal A′ does not continue to transmit the frame for the time 2Tm+Tc. The frame length corresponding to this time 2Tm+Tc is the minimum frame length, and it is possible to detect a collision during the transmission of a frame irrespective of the positions of the terminals A′ and B′. Every terminal is prohibited from transmitting a frame having a frame length shorter than this. In transmitting information having a shorter frame length, meaningless information called ‘pad’ is sent idly so as to lengthen the frame length to the length corresponding to 2Tm+Tc. In this manner, if collision detection is carried out during the transmission of a frame, it is possible to detect any collision.
Since a LAN of the above-described CSMA/CD system adopts a first-come-first-served system, when any terminal A which is connected in the same segment, as shown in FIG. 35, is in the process of transmission of a frame, other terminal C cannot start transmission until the transmission by the terminal A is finished. That is, even if the terminal C wants to transmit a frame having a real-time-nature, the transmission is impossible until the terminal A has finished transmission. In addition, if a plurality of terminals start transmission at the same time, a collision occurs, so that a back-off processing is carried out and a strict QoS is not realized.
A method of controlling the reservation for the timing of transmitting a frame for the purpose of reducing the frequency of collisions when the load is high is proposed (Japanese Patent Laid-Open No. 46263/1995). According to this method, when communication is established between the terminals A and B, as shown in FIG. 36, (a) the time is adjusted to coincide between the terminals A, B, and the terminal A produces a time chart (FIG. 37) for making the reservation at intervals and alternately, transmits the time chart to the terminal B and negotiates with the terminal B so that the terminal B holds the time chart, (b) and the terminals A and B thereafter transmit frames in accordance with the time chart.
The CSMA/CD system suffers from a fundamental problem of the occurrence of a collision because it is impossible to know when each terminal starts the transmission of a frame. In the prior art aimed at the solution of this problem, it is necessary for each terminal to determine and hold a common time chart by previous negotiation, and the time chart once determined is never updated. For this reason, the terminal C which is not set in the time chart cannot wedge itself into the queue so as to transmit a frame. In addition, although there is sometimes a case in which data to be transmitted are not produced from the upper layer (IP layer) as the time chart prescribes, no consideration is given to such a case in the prior art.